export default class SimpleObjVO  { 
  name!:string;
  id!:string;
  type!:number;


  /**通过JSONObject创建实例对象 */
  public static getInstanceByJSONObj(jsonObj:any):SimpleObjVO{  
    let instance=new SimpleObjVO()  
    return Object.assign(instance, jsonObj) 
  }


  /** 通过属性参数创建实例对象 */
  public static getInstanceByParam(name:string,id:string
                                   ,type:number){ 
    let instance=new SimpleObjVO()  
    instance.name=name;
    instance.id=id;
    instance.type=type;
    return instance 
  }


  /** 类属性的申明静态变量(适用于直接用到Class.fieldName的场景) */
   static fieldNames={
       name:"name",
      id:"id",
      type:"type" } 
}

